﻿// IService/IProductInformationService.cs
using Entity;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace IService
{
    public interface IProductInformationService
    {
        Task<ProductInformationEntity> GetByCodeAsync(string productCode);

        Task<PagedViewModel<ProductInformationFind>> GetByCodeAsync(int pageSize, int currentPage, string? code = null, string? Unit = null);

        Task<PageResult<ProductTableItem>> MultiConditionSearchAsync(ProductQueryParam param);

        Task<PageResult<ProductListItemDto>> SearchWithStockAsync(
            string? keyword, int outWarehouseId,
            int pageNum, int pageSize);

        // 统一搜索方法，使用可选参数
        Task<PageResult<ProductListItemDto>> SearchAsync(
            ProductSearchParam param,
            string warehouseName = null,
            string location = null);
    }
}